<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "https://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
<meta http-equiv="X-UA-Compatible" content="IE=9"/>
<meta name="generator" content="Doxygen 1.8.17"/>
<meta name="viewport" content="width=device-width, initial-scale=1"/>
<title>Jetson Inference: Color Conversion</title>
<link href="tabs.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="jquery.js"></script>
<script type="text/javascript" src="dynsections.js"></script>
<link href="navtree.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="resize.js"></script>
<script type="text/javascript" src="navtreedata.js"></script>
<script type="text/javascript" src="navtree.js"></script>
<link href="search/search.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="search/searchdata.js"></script>
<script type="text/javascript" src="search/search.js"></script>
<link href="doxygen.css" rel="stylesheet" type="text/css" />
</head>
<body>
<div id="top"><!-- do not remove this div, it is closed by doxygen! -->
<div id="titlearea">
<table cellspacing="0" cellpadding="0">
 <tbody>
 <tr style="height: 56px;">
  <td id="projectlogo"><img alt="Logo" src="NVLogo_2D.jpg"/></td>
  <td id="projectalign" style="padding-left: 0.5em;">
   <div id="projectname">Jetson Inference
   </div>
   <div id="projectbrief">DNN Vision Library</div>
  </td>
 </tr>
 </tbody>
</table>
</div>
<!-- end header part -->
<!-- Generated by Doxygen 1.8.17 -->
<script type="text/javascript">
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&amp;dn=gpl-2.0.txt GPL-v2 */
var searchBox = new SearchBox("searchBox", "search",false,'Search');
/* @license-end */
</script>
<script type="text/javascript" src="menudata.js"></script>
<script type="text/javascript" src="menu.js"></script>
<script type="text/javascript">
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&amp;dn=gpl-2.0.txt GPL-v2 */
$(function() {
  initMenu('',true,false,'search.php','Search');
  $(document).ready(function() { init_search(); });
});
/* @license-end */</script>
<div id="main-nav"></div>
</div><!-- top -->
<div id="side-nav" class="ui-resizable side-nav-resizable">
  <div id="nav-tree">
    <div id="nav-tree-contents">
      <div id="nav-sync" class="sync"></div>
    </div>
  </div>
  <div id="splitbar" style="-moz-user-select:none;" 
       class="ui-resizable-handle">
  </div>
</div>
<script type="text/javascript">
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&amp;dn=gpl-2.0.txt GPL-v2 */
$(document).ready(function(){initNavTree('group__colorspace.html',''); initResizable(); });
/* @license-end */
</script>
<div id="doc-content">
<!-- window showing the filter options -->
<div id="MSearchSelectWindow"
     onmouseover="return searchBox.OnSearchSelectShow()"
     onmouseout="return searchBox.OnSearchSelectHide()"
     onkeydown="return searchBox.OnSearchSelectKey(event)">
</div>

<!-- iframe showing the search results (closed by default) -->
<div id="MSearchResultsWindow">
<iframe src="javascript:void(0)" frameborder="0" 
        name="MSearchResults" id="MSearchResults">
</iframe>
</div>

<div class="header">
  <div class="summary">
<a href="#func-members">Functions</a>  </div>
  <div class="headertitle">
<div class="title">Color Conversion<div class="ingroups"><a class="el" href="group__util.html">Utilities Library (jetson-utils)</a> &raquo; <a class="el" href="group__cuda.html">CUDA</a></div></div>  </div>
</div><!--header-->
<div class="contents">

<p>Colorspace conversion functions for various YUV formats, RGB, BGR, Bayer, and grayscale.  
<a href="#details">More...</a></p>
<table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="func-members"></a>
Functions</h2></td></tr>
<tr class="memitem:ga2befa65dbc92689a36a367993d1ad673"><td class="memItemLeft" align="right" valign="top">cudaError_t&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__colorspace.html#ga2befa65dbc92689a36a367993d1ad673">cudaConvertColor</a> (void *input, <a class="el" href="group__imageFormat.html#ga931c48e08f361637d093355d64583406">imageFormat</a> inputFormat, void *output, <a class="el" href="group__imageFormat.html#ga931c48e08f361637d093355d64583406">imageFormat</a> outputFormat, size_t width, size_t height, const float2 &amp;pixel_range=<a class="el" href="cudaMath_8h.html#a931119b28bbeb119817cd0128f422a08">make_float2</a>(0, 255))</td></tr>
<tr class="memdesc:ga2befa65dbc92689a36a367993d1ad673"><td class="mdescLeft">&#160;</td><td class="mdescRight">Convert between two image formats using the GPU.  <a href="group__colorspace.html#ga2befa65dbc92689a36a367993d1ad673">More...</a><br /></td></tr>
<tr class="separator:ga2befa65dbc92689a36a367993d1ad673"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:gab092814e4f699dec48343fcb67e69a88"><td class="memTemplParams" colspan="2">template&lt;typename T_in , typename T_out &gt; </td></tr>
<tr class="memitem:gab092814e4f699dec48343fcb67e69a88"><td class="memTemplItemLeft" align="right" valign="top">cudaError_t&#160;</td><td class="memTemplItemRight" valign="bottom"><a class="el" href="group__colorspace.html#gab092814e4f699dec48343fcb67e69a88">cudaConvertColor</a> (T_in *input, T_out *output, size_t width, size_t height, const float2 &amp;pixel_range=<a class="el" href="cudaMath_8h.html#a931119b28bbeb119817cd0128f422a08">make_float2</a>(0, 255))</td></tr>
<tr class="memdesc:gab092814e4f699dec48343fcb67e69a88"><td class="mdescLeft">&#160;</td><td class="mdescRight">Convert between to image formats using the GPU.  <a href="group__colorspace.html#gab092814e4f699dec48343fcb67e69a88">More...</a><br /></td></tr>
<tr class="separator:gab092814e4f699dec48343fcb67e69a88"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table><table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="member-group"></a>
8-bit grayscale to floating-point grayscale (and vice versa)</h2></td></tr>
<tr><td class="ititle" colspan="2"><p><a class="anchor" id="amgrpeec60b3ae58be224df19c76e2aabc603"></a></p><dl class="section see"><dt>See also</dt><dd><a class="el" href="group__colorspace.html#ga2befa65dbc92689a36a367993d1ad673" title="Convert between two image formats using the GPU.">cudaConvertColor()</a> from <a class="el" href="cudaColorspace_8h.html">cudaColorspace.h</a> for automated format conversion </dd></dl>
</td></tr>
<tr class="memitem:gad2930b5da1adf112ea0d1fc2a4af6d7e"><td class="memItemLeft" align="right" valign="top">cudaError_t&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__colorspace.html#gad2930b5da1adf112ea0d1fc2a4af6d7e">cudaGray8ToGray32</a> (uint8_t *input, float *output, size_t width, size_t height)</td></tr>
<tr class="memdesc:gad2930b5da1adf112ea0d1fc2a4af6d7e"><td class="mdescLeft">&#160;</td><td class="mdescRight">Convert uint8 grayscale image into float grayscale.  <a href="group__colorspace.html#gad2930b5da1adf112ea0d1fc2a4af6d7e">More...</a><br /></td></tr>
<tr class="separator:gad2930b5da1adf112ea0d1fc2a4af6d7e"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:gaeda6bd828034411d2957fefa9bc7c86c"><td class="memItemLeft" align="right" valign="top">cudaError_t&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__colorspace.html#gaeda6bd828034411d2957fefa9bc7c86c">cudaGray32ToGray8</a> (float *input, uint8_t *output, size_t width, size_t height, const float2 &amp;pixelRange=<a class="el" href="cudaMath_8h.html#a931119b28bbeb119817cd0128f422a08">make_float2</a>(0, 255))</td></tr>
<tr class="memdesc:gaeda6bd828034411d2957fefa9bc7c86c"><td class="mdescLeft">&#160;</td><td class="mdescRight">Convert float grayscale image into uint8 grayscale.  <a href="group__colorspace.html#gaeda6bd828034411d2957fefa9bc7c86c">More...</a><br /></td></tr>
<tr class="separator:gaeda6bd828034411d2957fefa9bc7c86c"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table><table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="member-group"></a>
RGB/BGR to 8-bit grayscale</h2></td></tr>
<tr><td class="ititle" colspan="2"><p><a class="anchor" id="amgrp107ee73cf87cfd28e87b2dc88c90df5f"></a></p><dl class="section see"><dt>See also</dt><dd><a class="el" href="group__colorspace.html#ga2befa65dbc92689a36a367993d1ad673" title="Convert between two image formats using the GPU.">cudaConvertColor()</a> from <a class="el" href="cudaColorspace_8h.html">cudaColorspace.h</a> for automated format conversion </dd></dl>
</td></tr>
<tr class="memitem:ga38d17b06ac4d2ffdb4b297cdda88d132"><td class="memItemLeft" align="right" valign="top">cudaError_t&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__colorspace.html#ga38d17b06ac4d2ffdb4b297cdda88d132">cudaRGB8ToGray8</a> (uchar3 *input, uint8_t *output, size_t width, size_t height, bool swapRedBlue=false)</td></tr>
<tr class="memdesc:ga38d17b06ac4d2ffdb4b297cdda88d132"><td class="mdescLeft">&#160;</td><td class="mdescRight">Convert uchar3 RGB/BGR image into uint8 grayscale.  <a href="group__colorspace.html#ga38d17b06ac4d2ffdb4b297cdda88d132">More...</a><br /></td></tr>
<tr class="separator:ga38d17b06ac4d2ffdb4b297cdda88d132"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ga1e4fbd03bd987c426abdfba35dc44e54"><td class="memItemLeft" align="right" valign="top">cudaError_t&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__colorspace.html#ga1e4fbd03bd987c426abdfba35dc44e54">cudaRGBA8ToGray8</a> (uchar4 *input, uint8_t *output, size_t width, size_t height, bool swapRedBlue=false)</td></tr>
<tr class="memdesc:ga1e4fbd03bd987c426abdfba35dc44e54"><td class="mdescLeft">&#160;</td><td class="mdescRight">Convert uchar4 RGBA/BGRA image into uint8 grayscale.  <a href="group__colorspace.html#ga1e4fbd03bd987c426abdfba35dc44e54">More...</a><br /></td></tr>
<tr class="separator:ga1e4fbd03bd987c426abdfba35dc44e54"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ga05a851ab406d65c1f2f47e51ce771cbb"><td class="memItemLeft" align="right" valign="top">cudaError_t&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__colorspace.html#ga05a851ab406d65c1f2f47e51ce771cbb">cudaRGB32ToGray8</a> (float3 *input, uint8_t *output, size_t width, size_t height, bool swapRedBlue=false, const float2 &amp;pixelRange=<a class="el" href="cudaMath_8h.html#a931119b28bbeb119817cd0128f422a08">make_float2</a>(0, 255))</td></tr>
<tr class="memdesc:ga05a851ab406d65c1f2f47e51ce771cbb"><td class="mdescLeft">&#160;</td><td class="mdescRight">Convert float3 RGB/BGR image into uint8 grayscale.  <a href="group__colorspace.html#ga05a851ab406d65c1f2f47e51ce771cbb">More...</a><br /></td></tr>
<tr class="separator:ga05a851ab406d65c1f2f47e51ce771cbb"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:gae29c5520d17fdfe5e5cc046392cba334"><td class="memItemLeft" align="right" valign="top">cudaError_t&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__colorspace.html#gae29c5520d17fdfe5e5cc046392cba334">cudaRGBA32ToGray8</a> (float4 *input, uint8_t *output, size_t width, size_t height, bool swapRedBlue=false, const float2 &amp;pixelRange=<a class="el" href="cudaMath_8h.html#a931119b28bbeb119817cd0128f422a08">make_float2</a>(0, 255))</td></tr>
<tr class="memdesc:gae29c5520d17fdfe5e5cc046392cba334"><td class="mdescLeft">&#160;</td><td class="mdescRight">Convert float4 RGBA/BGRA image into uint8 grayscale.  <a href="group__colorspace.html#gae29c5520d17fdfe5e5cc046392cba334">More...</a><br /></td></tr>
<tr class="separator:gae29c5520d17fdfe5e5cc046392cba334"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table><table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="member-group"></a>
RGB/BGR to floating-point grayscale</h2></td></tr>
<tr><td class="ititle" colspan="2"><p><a class="anchor" id="amgrpc5252317a511414723deb7d4ecffbf76"></a></p><dl class="section see"><dt>See also</dt><dd><a class="el" href="group__colorspace.html#ga2befa65dbc92689a36a367993d1ad673" title="Convert between two image formats using the GPU.">cudaConvertColor()</a> from <a class="el" href="cudaColorspace_8h.html">cudaColorspace.h</a> for automated format conversion </dd></dl>
</td></tr>
<tr class="memitem:ga7e65db0b95cd45e85296ba9db9f56621"><td class="memItemLeft" align="right" valign="top">cudaError_t&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__colorspace.html#ga7e65db0b95cd45e85296ba9db9f56621">cudaRGB8ToGray32</a> (uchar3 *input, float *output, size_t width, size_t height, bool swapRedBlue=false)</td></tr>
<tr class="memdesc:ga7e65db0b95cd45e85296ba9db9f56621"><td class="mdescLeft">&#160;</td><td class="mdescRight">Convert uchar3 RGB/BGR image into float grayscale.  <a href="group__colorspace.html#ga7e65db0b95cd45e85296ba9db9f56621">More...</a><br /></td></tr>
<tr class="separator:ga7e65db0b95cd45e85296ba9db9f56621"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ga76480ff68415cfc5ebe52ff4ee1dba18"><td class="memItemLeft" align="right" valign="top">cudaError_t&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__colorspace.html#ga76480ff68415cfc5ebe52ff4ee1dba18">cudaRGBA8ToGray32</a> (uchar4 *input, float *output, size_t width, size_t height, bool swapRedBlue=false)</td></tr>
<tr class="memdesc:ga76480ff68415cfc5ebe52ff4ee1dba18"><td class="mdescLeft">&#160;</td><td class="mdescRight">Convert uchar4 RGBA/BGRA image into float grayscale.  <a href="group__colorspace.html#ga76480ff68415cfc5ebe52ff4ee1dba18">More...</a><br /></td></tr>
<tr class="separator:ga76480ff68415cfc5ebe52ff4ee1dba18"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:gab4a99353101747d552ea86c56bda2c07"><td class="memItemLeft" align="right" valign="top">cudaError_t&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__colorspace.html#gab4a99353101747d552ea86c56bda2c07">cudaRGB32ToGray32</a> (float3 *input, float *output, size_t width, size_t height, bool swapRedBlue=false)</td></tr>
<tr class="memdesc:gab4a99353101747d552ea86c56bda2c07"><td class="mdescLeft">&#160;</td><td class="mdescRight">Convert float3 RGB/BGR image into float grayscale.  <a href="group__colorspace.html#gab4a99353101747d552ea86c56bda2c07">More...</a><br /></td></tr>
<tr class="separator:gab4a99353101747d552ea86c56bda2c07"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:gac098220252c68f4adc86d38d781878c7"><td class="memItemLeft" align="right" valign="top">cudaError_t&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__colorspace.html#gac098220252c68f4adc86d38d781878c7">cudaRGBA32ToGray32</a> (float4 *input, float *output, size_t width, size_t height, bool swapRedBlue=false)</td></tr>
<tr class="memdesc:gac098220252c68f4adc86d38d781878c7"><td class="mdescLeft">&#160;</td><td class="mdescRight">Convert float4 RGB/BGR image into float grayscale.  <a href="group__colorspace.html#gac098220252c68f4adc86d38d781878c7">More...</a><br /></td></tr>
<tr class="separator:gac098220252c68f4adc86d38d781878c7"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table><table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="member-group"></a>
8-bit grayscale to RGB/BGR</h2></td></tr>
<tr><td class="ititle" colspan="2"><p><a class="anchor" id="amgrpe3cd941eb92071b40e7b32565874501c"></a></p><dl class="section see"><dt>See also</dt><dd><a class="el" href="group__colorspace.html#ga2befa65dbc92689a36a367993d1ad673" title="Convert between two image formats using the GPU.">cudaConvertColor()</a> from <a class="el" href="cudaColorspace_8h.html">cudaColorspace.h</a> for automated format conversion </dd></dl>
</td></tr>
<tr class="memitem:gab37fe8aab37f309b90dc3b7df33fea22"><td class="memItemLeft" align="right" valign="top">cudaError_t&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__colorspace.html#gab37fe8aab37f309b90dc3b7df33fea22">cudaGray8ToRGB8</a> (uint8_t *input, uchar3 *output, size_t width, size_t height)</td></tr>
<tr class="memdesc:gab37fe8aab37f309b90dc3b7df33fea22"><td class="mdescLeft">&#160;</td><td class="mdescRight">Convert uint8 grayscale image into uchar3 RGB/BGR.  <a href="group__colorspace.html#gab37fe8aab37f309b90dc3b7df33fea22">More...</a><br /></td></tr>
<tr class="separator:gab37fe8aab37f309b90dc3b7df33fea22"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ga866ad8f2da224d6403ce6ea6a3e36f85"><td class="memItemLeft" align="right" valign="top">cudaError_t&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__colorspace.html#ga866ad8f2da224d6403ce6ea6a3e36f85">cudaGray8ToRGBA8</a> (uint8_t *input, uchar4 *output, size_t width, size_t height)</td></tr>
<tr class="memdesc:ga866ad8f2da224d6403ce6ea6a3e36f85"><td class="mdescLeft">&#160;</td><td class="mdescRight">Convert uint8 grayscale image into uchar4 RGB/BGR.  <a href="group__colorspace.html#ga866ad8f2da224d6403ce6ea6a3e36f85">More...</a><br /></td></tr>
<tr class="separator:ga866ad8f2da224d6403ce6ea6a3e36f85"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ga8924f2b6d7b21c1c2f73e868e331592a"><td class="memItemLeft" align="right" valign="top">cudaError_t&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__colorspace.html#ga8924f2b6d7b21c1c2f73e868e331592a">cudaGray8ToRGB32</a> (uint8_t *input, float3 *output, size_t width, size_t height)</td></tr>
<tr class="memdesc:ga8924f2b6d7b21c1c2f73e868e331592a"><td class="mdescLeft">&#160;</td><td class="mdescRight">Convert uint8 grayscale image into float3 RGB/BGR.  <a href="group__colorspace.html#ga8924f2b6d7b21c1c2f73e868e331592a">More...</a><br /></td></tr>
<tr class="separator:ga8924f2b6d7b21c1c2f73e868e331592a"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:gae3ecc5983890fc3846befedc01872a44"><td class="memItemLeft" align="right" valign="top">cudaError_t&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__colorspace.html#gae3ecc5983890fc3846befedc01872a44">cudaGray8ToRGBA32</a> (uint8_t *input, float4 *output, size_t width, size_t height)</td></tr>
<tr class="memdesc:gae3ecc5983890fc3846befedc01872a44"><td class="mdescLeft">&#160;</td><td class="mdescRight">Convert uint8 grayscale image into float4 RGB/BGR.  <a href="group__colorspace.html#gae3ecc5983890fc3846befedc01872a44">More...</a><br /></td></tr>
<tr class="separator:gae3ecc5983890fc3846befedc01872a44"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table><table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="member-group"></a>
Floating-point grayscale to RGB/BGR</h2></td></tr>
<tr><td class="ititle" colspan="2"><p><a class="anchor" id="amgrpfede93ec62e231cce9b573e1aafd77c3"></a></p><dl class="section see"><dt>See also</dt><dd><a class="el" href="group__colorspace.html#ga2befa65dbc92689a36a367993d1ad673" title="Convert between two image formats using the GPU.">cudaConvertColor()</a> from <a class="el" href="cudaColorspace_8h.html">cudaColorspace.h</a> for automated format conversion </dd></dl>
</td></tr>
<tr class="memitem:ga743d366c32e2dce7a9c57762fe525ca8"><td class="memItemLeft" align="right" valign="top">cudaError_t&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__colorspace.html#ga743d366c32e2dce7a9c57762fe525ca8">cudaGray32ToRGB8</a> (float *input, uchar3 *output, size_t width, size_t height, const float2 &amp;pixelRange=<a class="el" href="cudaMath_8h.html#a931119b28bbeb119817cd0128f422a08">make_float2</a>(0, 255))</td></tr>
<tr class="memdesc:ga743d366c32e2dce7a9c57762fe525ca8"><td class="mdescLeft">&#160;</td><td class="mdescRight">Convert float grayscale image into uchar3 RGB/BGR.  <a href="group__colorspace.html#ga743d366c32e2dce7a9c57762fe525ca8">More...</a><br /></td></tr>
<tr class="separator:ga743d366c32e2dce7a9c57762fe525ca8"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:gaf83b1be3204def331413fbf776aa3df3"><td class="memItemLeft" align="right" valign="top">cudaError_t&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__colorspace.html#gaf83b1be3204def331413fbf776aa3df3">cudaGray32ToRGBA8</a> (float *input, uchar4 *output, size_t width, size_t height, const float2 &amp;pixelRange=<a class="el" href="cudaMath_8h.html#a931119b28bbeb119817cd0128f422a08">make_float2</a>(0, 255))</td></tr>
<tr class="memdesc:gaf83b1be3204def331413fbf776aa3df3"><td class="mdescLeft">&#160;</td><td class="mdescRight">Convert float grayscale image into uchar4 RGB/BGR.  <a href="group__colorspace.html#gaf83b1be3204def331413fbf776aa3df3">More...</a><br /></td></tr>
<tr class="separator:gaf83b1be3204def331413fbf776aa3df3"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:gabccc05a436032389da3f779e2cef98b4"><td class="memItemLeft" align="right" valign="top">cudaError_t&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__colorspace.html#gabccc05a436032389da3f779e2cef98b4">cudaGray32ToRGB32</a> (float *input, float3 *output, size_t width, size_t height)</td></tr>
<tr class="memdesc:gabccc05a436032389da3f779e2cef98b4"><td class="mdescLeft">&#160;</td><td class="mdescRight">Convert float grayscale image into float3 RGB/BGR.  <a href="group__colorspace.html#gabccc05a436032389da3f779e2cef98b4">More...</a><br /></td></tr>
<tr class="separator:gabccc05a436032389da3f779e2cef98b4"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ga08968447eca071e40810d7e94e954375"><td class="memItemLeft" align="right" valign="top">cudaError_t&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__colorspace.html#ga08968447eca071e40810d7e94e954375">cudaGray32ToRGBA32</a> (float *input, float4 *output, size_t width, size_t height)</td></tr>
<tr class="memdesc:ga08968447eca071e40810d7e94e954375"><td class="mdescLeft">&#160;</td><td class="mdescRight">Convert float grayscale image into float4 RGB/BGR.  <a href="group__colorspace.html#ga08968447eca071e40810d7e94e954375">More...</a><br /></td></tr>
<tr class="separator:ga08968447eca071e40810d7e94e954375"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table>
<a name="details" id="details"></a><h2 class="groupheader">Detailed Description</h2>
<p>Colorspace conversion functions for various YUV formats, RGB, BGR, Bayer, and grayscale. </p>
<dl class="section see"><dt>See also</dt><dd><a class="el" href="group__colorspace.html#gab092814e4f699dec48343fcb67e69a88" title="Convert between to image formats using the GPU.">cudaConvertColor</a> for automated format conversion. </dd>
<dd>
<a class="el" href="cudaYUV_8h.html">cudaYUV.h</a> for the YUV functions. </dd></dl>
<h2 class="groupheader">Function Documentation</h2>
<a id="gab092814e4f699dec48343fcb67e69a88"></a>
<h2 class="memtitle"><span class="permalink"><a href="#gab092814e4f699dec48343fcb67e69a88">&#9670;&nbsp;</a></span>cudaConvertColor() <span class="overload">[1/2]</span></h2>

<div class="memitem">
<div class="memproto">
<div class="memtemplate">
template&lt;typename T_in , typename T_out &gt; </div>
      <table class="memname">
        <tr>
          <td class="memname">cudaError_t cudaConvertColor </td>
          <td>(</td>
          <td class="paramtype">T_in *&#160;</td>
          <td class="paramname"><em>input</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">T_out *&#160;</td>
          <td class="paramname"><em>output</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">size_t&#160;</td>
          <td class="paramname"><em>width</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">size_t&#160;</td>
          <td class="paramname"><em>height</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">const float2 &amp;&#160;</td>
          <td class="paramname"><em>pixel_range</em> = <code><a class="el" href="cudaMath_8h.html#a931119b28bbeb119817cd0128f422a08">make_float2</a>(0,255)</code>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Convert between to image formats using the GPU. </p>
<p>This templated overload of <a class="el" href="group__colorspace.html#ga2befa65dbc92689a36a367993d1ad673" title="Convert between two image formats using the GPU.">cudaConvertColor()</a> supports uchar3 (<code>IMAGE_RGB8</code>), uchar4 (<code>IMAGE_RGBA8</code>), float3 (<code>IMAGE_RGB32F</code>), and float4 (<code>IMAGE_RGBA32F</code>).</p>
<p>To convert to/from other formats such as YUV, grayscale, and BGR/BGRA, see the other version of <a class="el" href="group__colorspace.html#ga2befa65dbc92689a36a367993d1ad673" title="Convert between two image formats using the GPU.">cudaConvertColor()</a> that uses explicity imageFormat enums.</p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">input</td><td>CUDA device pointer to the input image </td></tr>
    <tr><td class="paramname">output</td><td>CUDA device pointer to the input image </td></tr>
    <tr><td class="paramname">width</td><td>width of the input and output images (in pixels) </td></tr>
    <tr><td class="paramname">height</td><td>height of the input and output images (in pixels) </td></tr>
    <tr><td class="paramname">pixel_range</td><td>for floating-point to 8-bit conversions, specifies the range of pixel intensities in the input image that get normalized to <code>[0,255]</code>. The default input range is <code>[0,255]</code>, and as such no normalization occurs. Other common pixel ranges include <code>[0,1]</code> and <code>[-1,1]</code>, and these pixel values would be re-scaled for <code>[0,255]</code> output. Note that this parameter is only used for float-to-uchar conversions where the data is downcast (for example, <code>IMAGE_RGB32F</code> to <code>IMAGE_RGB8</code>). </td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
<a id="ga2befa65dbc92689a36a367993d1ad673"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ga2befa65dbc92689a36a367993d1ad673">&#9670;&nbsp;</a></span>cudaConvertColor() <span class="overload">[2/2]</span></h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">cudaError_t cudaConvertColor </td>
          <td>(</td>
          <td class="paramtype">void *&#160;</td>
          <td class="paramname"><em>input</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="group__imageFormat.html#ga931c48e08f361637d093355d64583406">imageFormat</a>&#160;</td>
          <td class="paramname"><em>inputFormat</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">void *&#160;</td>
          <td class="paramname"><em>output</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="group__imageFormat.html#ga931c48e08f361637d093355d64583406">imageFormat</a>&#160;</td>
          <td class="paramname"><em>outputFormat</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">size_t&#160;</td>
          <td class="paramname"><em>width</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">size_t&#160;</td>
          <td class="paramname"><em>height</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">const float2 &amp;&#160;</td>
          <td class="paramname"><em>pixel_range</em> = <code><a class="el" href="cudaMath_8h.html#a931119b28bbeb119817cd0128f422a08">make_float2</a>(0,&#160;255)</code>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Convert between two image formats using the GPU. </p>
<p>This function supports various conversions between RGB/RGBA, BGR/BGRA, Bayer, grayscale, and YUV. In addition to converting between the previously listed colorspaces, you can also change the number of channels or data format (for example, <code>IMAGE_RGB8</code> to <code>IMAGE_RGBA32F</code>).</p>
<p>For the list of image formats available, </p><dl class="section see"><dt>See also</dt><dd><a class="el" href="group__imageFormat.html#ga931c48e08f361637d093355d64583406" title="The imageFormat enum is used to identify the pixel format and colorspace of an image.">imageFormat</a> enum.</dd></dl>
<p>Limitations and unsupported conversions include: </p><pre class="fragment">- The YUV formats don't support BGR/BGRA or grayscale (RGB/RGBA only)
- YUV NV12, YUYV, YVYU, and UYVY can only be converted to RGB/RGBA (not from)
- Bayer formats can only be converted to RGB8 (`uchar3`) and RGBA8 (`uchar4`)
</pre><dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">input</td><td>CUDA device pointer to the input image </td></tr>
    <tr><td class="paramname">inputFormat</td><td>format enum of the input image </td></tr>
    <tr><td class="paramname">output</td><td>CUDA device pointer to the input image </td></tr>
    <tr><td class="paramname">outputFormat</td><td>format enum of the output image </td></tr>
    <tr><td class="paramname">width</td><td>width of the input and output images (in pixels) </td></tr>
    <tr><td class="paramname">height</td><td>height of the input and output images (in pixels) </td></tr>
    <tr><td class="paramname">pixel_range</td><td>for floating-point to 8-bit conversions, specifies the range of pixel intensities in the input image that get normalized to <code>[0,255]</code>. The default input range is <code>[0,255]</code>, and as such no normalization occurs. Other common pixel ranges include <code>[0,1]</code> and <code>[-1,1]</code>, and these pixel values would be re-scaled for <code>[0,255]</code> output. Note that this parameter is only used for float-to-uchar conversions where the data is downcast (for example, <code>IMAGE_RGB32F</code> to <code>IMAGE_RGB8</code>). </td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
<a id="gaeda6bd828034411d2957fefa9bc7c86c"></a>
<h2 class="memtitle"><span class="permalink"><a href="#gaeda6bd828034411d2957fefa9bc7c86c">&#9670;&nbsp;</a></span>cudaGray32ToGray8()</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">cudaError_t cudaGray32ToGray8 </td>
          <td>(</td>
          <td class="paramtype">float *&#160;</td>
          <td class="paramname"><em>input</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">uint8_t *&#160;</td>
          <td class="paramname"><em>output</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">size_t&#160;</td>
          <td class="paramname"><em>width</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">size_t&#160;</td>
          <td class="paramname"><em>height</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">const float2 &amp;&#160;</td>
          <td class="paramname"><em>pixelRange</em> = <code><a class="el" href="cudaMath_8h.html#a931119b28bbeb119817cd0128f422a08">make_float2</a>(0,&#160;255)</code>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Convert float grayscale image into uint8 grayscale. </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">pixelRange</td><td>specifies the floating-point pixel value range of the input image, which is used to rescale the fixed-point pixel outputs to [0,255]. The default input range is [0,255], where no rescaling occurs. Other common input ranges are [-1, 1] or [0,1]. </td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
<a id="gabccc05a436032389da3f779e2cef98b4"></a>
<h2 class="memtitle"><span class="permalink"><a href="#gabccc05a436032389da3f779e2cef98b4">&#9670;&nbsp;</a></span>cudaGray32ToRGB32()</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">cudaError_t cudaGray32ToRGB32 </td>
          <td>(</td>
          <td class="paramtype">float *&#160;</td>
          <td class="paramname"><em>input</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">float3 *&#160;</td>
          <td class="paramname"><em>output</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">size_t&#160;</td>
          <td class="paramname"><em>width</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">size_t&#160;</td>
          <td class="paramname"><em>height</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Convert float grayscale image into float3 RGB/BGR. </p>

</div>
</div>
<a id="ga743d366c32e2dce7a9c57762fe525ca8"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ga743d366c32e2dce7a9c57762fe525ca8">&#9670;&nbsp;</a></span>cudaGray32ToRGB8()</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">cudaError_t cudaGray32ToRGB8 </td>
          <td>(</td>
          <td class="paramtype">float *&#160;</td>
          <td class="paramname"><em>input</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">uchar3 *&#160;</td>
          <td class="paramname"><em>output</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">size_t&#160;</td>
          <td class="paramname"><em>width</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">size_t&#160;</td>
          <td class="paramname"><em>height</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">const float2 &amp;&#160;</td>
          <td class="paramname"><em>pixelRange</em> = <code><a class="el" href="cudaMath_8h.html#a931119b28bbeb119817cd0128f422a08">make_float2</a>(0,&#160;255)</code>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Convert float grayscale image into uchar3 RGB/BGR. </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">pixelRange</td><td>specifies the floating-point pixel value range of the input image, </td></tr>
    <tr><td class="paramname">pixelRange</td><td>specifies the floating-point pixel value range of the input image, which is used to rescale the fixed-point pixel outputs to [0,255]. The default input range is [0,255], where no rescaling occurs. Other common input ranges are [-1, 1] or [0,1]. </td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
<a id="ga08968447eca071e40810d7e94e954375"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ga08968447eca071e40810d7e94e954375">&#9670;&nbsp;</a></span>cudaGray32ToRGBA32()</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">cudaError_t cudaGray32ToRGBA32 </td>
          <td>(</td>
          <td class="paramtype">float *&#160;</td>
          <td class="paramname"><em>input</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">float4 *&#160;</td>
          <td class="paramname"><em>output</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">size_t&#160;</td>
          <td class="paramname"><em>width</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">size_t&#160;</td>
          <td class="paramname"><em>height</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Convert float grayscale image into float4 RGB/BGR. </p>

</div>
</div>
<a id="gaf83b1be3204def331413fbf776aa3df3"></a>
<h2 class="memtitle"><span class="permalink"><a href="#gaf83b1be3204def331413fbf776aa3df3">&#9670;&nbsp;</a></span>cudaGray32ToRGBA8()</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">cudaError_t cudaGray32ToRGBA8 </td>
          <td>(</td>
          <td class="paramtype">float *&#160;</td>
          <td class="paramname"><em>input</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">uchar4 *&#160;</td>
          <td class="paramname"><em>output</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">size_t&#160;</td>
          <td class="paramname"><em>width</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">size_t&#160;</td>
          <td class="paramname"><em>height</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">const float2 &amp;&#160;</td>
          <td class="paramname"><em>pixelRange</em> = <code><a class="el" href="cudaMath_8h.html#a931119b28bbeb119817cd0128f422a08">make_float2</a>(0,&#160;255)</code>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Convert float grayscale image into uchar4 RGB/BGR. </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">pixelRange</td><td>specifies the floating-point pixel value range of the input image, which is used to rescale the fixed-point pixel outputs to [0,255]. The default input range is [0,255], where no rescaling occurs. Other common input ranges are [-1, 1] or [0,1]. </td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
<a id="gad2930b5da1adf112ea0d1fc2a4af6d7e"></a>
<h2 class="memtitle"><span class="permalink"><a href="#gad2930b5da1adf112ea0d1fc2a4af6d7e">&#9670;&nbsp;</a></span>cudaGray8ToGray32()</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">cudaError_t cudaGray8ToGray32 </td>
          <td>(</td>
          <td class="paramtype">uint8_t *&#160;</td>
          <td class="paramname"><em>input</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">float *&#160;</td>
          <td class="paramname"><em>output</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">size_t&#160;</td>
          <td class="paramname"><em>width</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">size_t&#160;</td>
          <td class="paramname"><em>height</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Convert uint8 grayscale image into float grayscale. </p>

</div>
</div>
<a id="ga8924f2b6d7b21c1c2f73e868e331592a"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ga8924f2b6d7b21c1c2f73e868e331592a">&#9670;&nbsp;</a></span>cudaGray8ToRGB32()</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">cudaError_t cudaGray8ToRGB32 </td>
          <td>(</td>
          <td class="paramtype">uint8_t *&#160;</td>
          <td class="paramname"><em>input</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">float3 *&#160;</td>
          <td class="paramname"><em>output</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">size_t&#160;</td>
          <td class="paramname"><em>width</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">size_t&#160;</td>
          <td class="paramname"><em>height</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Convert uint8 grayscale image into float3 RGB/BGR. </p>

</div>
</div>
<a id="gab37fe8aab37f309b90dc3b7df33fea22"></a>
<h2 class="memtitle"><span class="permalink"><a href="#gab37fe8aab37f309b90dc3b7df33fea22">&#9670;&nbsp;</a></span>cudaGray8ToRGB8()</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">cudaError_t cudaGray8ToRGB8 </td>
          <td>(</td>
          <td class="paramtype">uint8_t *&#160;</td>
          <td class="paramname"><em>input</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">uchar3 *&#160;</td>
          <td class="paramname"><em>output</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">size_t&#160;</td>
          <td class="paramname"><em>width</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">size_t&#160;</td>
          <td class="paramname"><em>height</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Convert uint8 grayscale image into uchar3 RGB/BGR. </p>

</div>
</div>
<a id="gae3ecc5983890fc3846befedc01872a44"></a>
<h2 class="memtitle"><span class="permalink"><a href="#gae3ecc5983890fc3846befedc01872a44">&#9670;&nbsp;</a></span>cudaGray8ToRGBA32()</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">cudaError_t cudaGray8ToRGBA32 </td>
          <td>(</td>
          <td class="paramtype">uint8_t *&#160;</td>
          <td class="paramname"><em>input</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">float4 *&#160;</td>
          <td class="paramname"><em>output</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">size_t&#160;</td>
          <td class="paramname"><em>width</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">size_t&#160;</td>
          <td class="paramname"><em>height</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Convert uint8 grayscale image into float4 RGB/BGR. </p>

</div>
</div>
<a id="ga866ad8f2da224d6403ce6ea6a3e36f85"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ga866ad8f2da224d6403ce6ea6a3e36f85">&#9670;&nbsp;</a></span>cudaGray8ToRGBA8()</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">cudaError_t cudaGray8ToRGBA8 </td>
          <td>(</td>
          <td class="paramtype">uint8_t *&#160;</td>
          <td class="paramname"><em>input</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">uchar4 *&#160;</td>
          <td class="paramname"><em>output</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">size_t&#160;</td>
          <td class="paramname"><em>width</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">size_t&#160;</td>
          <td class="paramname"><em>height</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Convert uint8 grayscale image into uchar4 RGB/BGR. </p>

</div>
</div>
<a id="gab4a99353101747d552ea86c56bda2c07"></a>
<h2 class="memtitle"><span class="permalink"><a href="#gab4a99353101747d552ea86c56bda2c07">&#9670;&nbsp;</a></span>cudaRGB32ToGray32()</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">cudaError_t cudaRGB32ToGray32 </td>
          <td>(</td>
          <td class="paramtype">float3 *&#160;</td>
          <td class="paramname"><em>input</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">float *&#160;</td>
          <td class="paramname"><em>output</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">size_t&#160;</td>
          <td class="paramname"><em>width</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">size_t&#160;</td>
          <td class="paramname"><em>height</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">bool&#160;</td>
          <td class="paramname"><em>swapRedBlue</em> = <code>false</code>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Convert float3 RGB/BGR image into float grayscale. </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">swapRedBlue</td><td>if true, swap the input's red and blue channels. The default is false, and the channels will remain the same. </td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
<a id="ga05a851ab406d65c1f2f47e51ce771cbb"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ga05a851ab406d65c1f2f47e51ce771cbb">&#9670;&nbsp;</a></span>cudaRGB32ToGray8()</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">cudaError_t cudaRGB32ToGray8 </td>
          <td>(</td>
          <td class="paramtype">float3 *&#160;</td>
          <td class="paramname"><em>input</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">uint8_t *&#160;</td>
          <td class="paramname"><em>output</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">size_t&#160;</td>
          <td class="paramname"><em>width</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">size_t&#160;</td>
          <td class="paramname"><em>height</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">bool&#160;</td>
          <td class="paramname"><em>swapRedBlue</em> = <code>false</code>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">const float2 &amp;&#160;</td>
          <td class="paramname"><em>pixelRange</em> = <code><a class="el" href="cudaMath_8h.html#a931119b28bbeb119817cd0128f422a08">make_float2</a>(0,&#160;255)</code>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Convert float3 RGB/BGR image into uint8 grayscale. </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">swapRedBlue</td><td>if true, swap the input's red and blue channels. The default is false, and the channels will remain the same.</td></tr>
    <tr><td class="paramname">pixelRange</td><td>specifies the floating-point pixel value range of the input image, which is used to rescale the fixed-point pixel outputs to [0,255]. The default input range is [0,255], where no rescaling occurs. Other common input ranges are [-1, 1] or [0,1]. </td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
<a id="ga7e65db0b95cd45e85296ba9db9f56621"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ga7e65db0b95cd45e85296ba9db9f56621">&#9670;&nbsp;</a></span>cudaRGB8ToGray32()</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">cudaError_t cudaRGB8ToGray32 </td>
          <td>(</td>
          <td class="paramtype">uchar3 *&#160;</td>
          <td class="paramname"><em>input</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">float *&#160;</td>
          <td class="paramname"><em>output</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">size_t&#160;</td>
          <td class="paramname"><em>width</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">size_t&#160;</td>
          <td class="paramname"><em>height</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">bool&#160;</td>
          <td class="paramname"><em>swapRedBlue</em> = <code>false</code>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Convert uchar3 RGB/BGR image into float grayscale. </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">swapRedBlue</td><td>if true, swap the input's red and blue channels. The default is false, and the channels will remain the same. </td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
<a id="ga38d17b06ac4d2ffdb4b297cdda88d132"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ga38d17b06ac4d2ffdb4b297cdda88d132">&#9670;&nbsp;</a></span>cudaRGB8ToGray8()</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">cudaError_t cudaRGB8ToGray8 </td>
          <td>(</td>
          <td class="paramtype">uchar3 *&#160;</td>
          <td class="paramname"><em>input</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">uint8_t *&#160;</td>
          <td class="paramname"><em>output</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">size_t&#160;</td>
          <td class="paramname"><em>width</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">size_t&#160;</td>
          <td class="paramname"><em>height</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">bool&#160;</td>
          <td class="paramname"><em>swapRedBlue</em> = <code>false</code>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Convert uchar3 RGB/BGR image into uint8 grayscale. </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">swapRedBlue</td><td>if true, swap the input's red and blue channels. The default is false, and the channels will remain the same. </td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
<a id="gac098220252c68f4adc86d38d781878c7"></a>
<h2 class="memtitle"><span class="permalink"><a href="#gac098220252c68f4adc86d38d781878c7">&#9670;&nbsp;</a></span>cudaRGBA32ToGray32()</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">cudaError_t cudaRGBA32ToGray32 </td>
          <td>(</td>
          <td class="paramtype">float4 *&#160;</td>
          <td class="paramname"><em>input</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">float *&#160;</td>
          <td class="paramname"><em>output</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">size_t&#160;</td>
          <td class="paramname"><em>width</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">size_t&#160;</td>
          <td class="paramname"><em>height</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">bool&#160;</td>
          <td class="paramname"><em>swapRedBlue</em> = <code>false</code>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Convert float4 RGB/BGR image into float grayscale. </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">swapRedBlue</td><td>if true, swap the input's red and blue channels. The default is false, and the channels will remain the same. </td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
<a id="gae29c5520d17fdfe5e5cc046392cba334"></a>
<h2 class="memtitle"><span class="permalink"><a href="#gae29c5520d17fdfe5e5cc046392cba334">&#9670;&nbsp;</a></span>cudaRGBA32ToGray8()</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">cudaError_t cudaRGBA32ToGray8 </td>
          <td>(</td>
          <td class="paramtype">float4 *&#160;</td>
          <td class="paramname"><em>input</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">uint8_t *&#160;</td>
          <td class="paramname"><em>output</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">size_t&#160;</td>
          <td class="paramname"><em>width</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">size_t&#160;</td>
          <td class="paramname"><em>height</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">bool&#160;</td>
          <td class="paramname"><em>swapRedBlue</em> = <code>false</code>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">const float2 &amp;&#160;</td>
          <td class="paramname"><em>pixelRange</em> = <code><a class="el" href="cudaMath_8h.html#a931119b28bbeb119817cd0128f422a08">make_float2</a>(0,&#160;255)</code>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Convert float4 RGBA/BGRA image into uint8 grayscale. </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">swapRedBlue</td><td>if true, swap the input's red and blue channels. The default is false, and the channels will remain the same.</td></tr>
    <tr><td class="paramname">pixelRange</td><td>specifies the floating-point pixel value range of the input image, which is used to rescale the fixed-point pixel outputs to [0,255]. The default input range is [0,255], where no rescaling occurs. Other common input ranges are [-1, 1] or [0,1]. </td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
<a id="ga76480ff68415cfc5ebe52ff4ee1dba18"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ga76480ff68415cfc5ebe52ff4ee1dba18">&#9670;&nbsp;</a></span>cudaRGBA8ToGray32()</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">cudaError_t cudaRGBA8ToGray32 </td>
          <td>(</td>
          <td class="paramtype">uchar4 *&#160;</td>
          <td class="paramname"><em>input</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">float *&#160;</td>
          <td class="paramname"><em>output</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">size_t&#160;</td>
          <td class="paramname"><em>width</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">size_t&#160;</td>
          <td class="paramname"><em>height</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">bool&#160;</td>
          <td class="paramname"><em>swapRedBlue</em> = <code>false</code>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Convert uchar4 RGBA/BGRA image into float grayscale. </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">swapRedBlue</td><td>if true, swap the input's red and blue channels. The default is false, and the channels will remain the same. </td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
<a id="ga1e4fbd03bd987c426abdfba35dc44e54"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ga1e4fbd03bd987c426abdfba35dc44e54">&#9670;&nbsp;</a></span>cudaRGBA8ToGray8()</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">cudaError_t cudaRGBA8ToGray8 </td>
          <td>(</td>
          <td class="paramtype">uchar4 *&#160;</td>
          <td class="paramname"><em>input</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">uint8_t *&#160;</td>
          <td class="paramname"><em>output</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">size_t&#160;</td>
          <td class="paramname"><em>width</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">size_t&#160;</td>
          <td class="paramname"><em>height</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">bool&#160;</td>
          <td class="paramname"><em>swapRedBlue</em> = <code>false</code>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Convert uchar4 RGBA/BGRA image into uint8 grayscale. </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">swapRedBlue</td><td>if true, swap the input's red and blue channels. The default is false, and the channels will remain the same. </td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
</div><!-- contents -->
</div><!-- doc-content -->
<!-- start footer part -->
<div id="nav-path" class="navpath"><!-- id is needed for treeview function! -->
  <ul>
    <li class="footer">Generated on Tue Mar 28 2023 14:27:58 for Jetson Inference by
    <a href="http://www.doxygen.org/index.html">
    <img class="footer" src="doxygen.png" alt="doxygen"/></a> 1.8.17 </li>
  </ul>
</div>
</body>
</html>
